package com.wxandroid.guidedemo.fragment;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;

import com.wxandroid.guidedemo.R;

/**
 * Created by Administrator on 2016/12/17.
 */

public class GuideFragment extends BaseFragment {


    private int imgRes;
    private ImageView imageView;
    private View rootView;

    @Override
    public void initData() {
        super.initData();
        Bundle arguments = getArguments();
        if (arguments != null) {
            imgRes = arguments.getInt("imgRes", -1);
        }

    }

    @Override
    public View initView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        rootView = inflater.inflate(R.layout.fragment_guide, container, false);
        imageView = (ImageView) rootView.findViewById(R.id.iv_guide_up);
        return rootView;
    }


    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

    }

    @Override
    public void fillData() {
        if (imgRes != -1) {
            imageView.setImageResource(imgRes);
        }
    }

    @Override
    public void requestData() {

    }
}
